#ifndef OBJANIM_H
#define OBJANIM_H

#include <string>
#include <list>
#include "vertex.h"
#include "vertexnormal.h"
#include "vtexcoord.h"
#include "triangle.h"

#include "objobject.h"

//forward declaration
//class Triangle;

class OBJAnim {

	public:
		OBJAnim();
		~OBJAnim();
	
	void setUniqName(std::string uniqName);
	OBJObject* getFrame(int i);

	//total number of frames
	int m_numFrames;
	int m_visible;
	int m_animationEnabled;

	//last frame number that was requested with getFrame
	int m_lastFrame;

	void enableAnim(void);
	void disableAnim(void);

	//target fps for "correct" animation
	float m_fps;

	GLfloat m_worldX;
	GLfloat m_worldY;
	GLfloat m_worldZ;

	void setWorldCoords(GLfloat x, GLfloat y, GLfloat z);

	std::string m_uniqName;	

	std::string m_texturefilename;
	
	std::list <OBJObject*> m_objobjectList;

};

#endif
